package com.ascalotoru;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.List;
import java.util.Properties;

import twitter4j.Status;
import twitter4j.Twitter;
import twitter4j.TwitterException;
import twitter4j.TwitterFactory;
import twitter4j.conf.ConfigurationBuilder;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.Toast;

public class TwitPostActivity extends Activity {
    /** Called when the activity is first created. */
	
    @Override
    public void onCreate(Bundle savedInstanceState) {
    	super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        
        ConfigurationBuilder cb = new ConfigurationBuilder();
        cb.setDebugEnabled(true)
          .setOAuthConsumerKey("qnCheavAeGLvdRTqqjbA")
          .setOAuthConsumerSecret("5iFMyxLcFrvbP1CIasw6DCBpzc3GAPMNZWVsMpf4yw")
          .setOAuthAccessToken("18002770-jDWYim7sSYOL9xlWPzHSkQrMKYbIiQkgPYEc9t5Nl")
          .setOAuthAccessTokenSecret("ikDRss3m2sJ0xb41S1j8okVCGnrvKuaEBcvw9srLlU");
        TwitterFactory tf = new TwitterFactory(cb.build());
        Twitter twitter = tf.getInstance();
        
        try {
			//Status status = twitter.updateStatus("Prueba");
			//System.out.println("OK");
        	List<Status> statuses = twitter.getHomeTimeline();
		} catch (TwitterException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
        
        
        
    }
}